<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>简化对象写法</title>
</head>
<body>
    <script>
        //声明变量 
        let name = 'H5201125';
        let type = '勤奋, 高富帅';
        let improve = function(){
            console.log('提升自己');
        };

        //声明一个对象
        let h5201125 = {
            //简写
            name,
            type,
            improve,
            //方法的简写
            change(){
                console.log('改变自己');
            }
        }

        console.log(h5201125);
    </script>
</body>
</html>